package com.qfedu.mavenk.di;

import com.qfedu.mavenk.beanDemo3.App07;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.stereotype.Component;

import java.util.*;

/**
 * @author:huayuzhuo
 * @email:2798866329@qq.com
 * @desc: 用来测试bean的类,目标类
 * @datatime: 2022/10/18 10:18
 */
@Component
public class User {
    private int id;
    private String password;
    private String sex;
    private int age;
    private Date birthday;
    private String[ ] hobbys;
    private Set<String> phones;
    private List<String> names;
    private Map<String,String> countries;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public String[] getHobbys() {
        return hobbys;
    }

    public void setHobbys(String[] hobbys) {
        this.hobbys = hobbys;
    }

    public Set<String> getPhones() {
        return phones;
    }

    public void setPhones(Set<String> phones) {
        this.phones = phones;
    }

    public List<String> getNames() {
        return names;
    }

    public void setNames(List<String> names) {
        this.names = names;
    }

    public Map<String, String> getCountries() {
        return countries;
    }

    public void setCountries(Map<String, String> countries) {
        this.countries = countries;
    }

    public User() {
    }

    public User(int id, String password, String sex, int age, Date birthday, String[] hobbys, Set<String> phones, List<String> names, Map<String, String> countries) {
        this.id = id;
        this.password = password;
        this.sex = sex;
        this.age = age;
        this.birthday = birthday;
        this.hobbys = hobbys;
        this.phones = phones;
        this.names = names;
        this.countries = countries;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", password='" + password + '\'' +
                ", sex='" + sex + '\'' +
                ", age=" + age +
                ", birthday=" + birthday +
                ", hobbys=" + Arrays.toString(hobbys) +
                ", phones=" + phones +
                ", names=" + names +
                ", countries=" + countries +
                '}';
    }

}
